home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 2 / AACD 2.iso / AACD / Programming / fpc / amigaunits / asl.pas < prev    next >
Pascal/Delphi Source File  |  1998-09-22  |  19KB  |  499 lines

  1. {
  2.     This file is part of the Free Pascal run time library.
  3.  
  4.     A file in Amiga system run time library.
  5.     Copyright (c) 1998 by Nils Sjoholm
  6.     member of the Amiga RTL development team.
  7.  
  8.     See the file COPYING.FPC, included in this distribution,
  9.     for details about the copyright.
  10.  
  11.     This program is distributed in the hope that it will be useful,
  12.     but WITHOUT ANY WARRANTY; without even the implied warranty of
  13.     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  14.  
  15.  **********************************************************************}
  16.  
  17. UNIT asl;
  18.  
  19. INTERFACE
  20. uses exec, utility, workbench, graphics;
  21.  
  22. {************************************************************************}
  23.  
  24. CONST
  25.   ASLNAME : PChar = 'asl.library';
  26.   ASL_TB          =     TAG_USER+$80000;
  27.  
  28. {************************************************************************}
  29.  
  30. { Types of requesters known to ASL, used as arguments to AllocAslRequest() }
  31.   ASL_FileRequest       = 0;
  32.   ASL_FontRequest       = 1;
  33.   ASL_ScreenModeRequest = 2;
  34.  
  35.  
  36. {****************************************************************************
  37.  *
  38.  * ASL File Requester data structures and constants
  39.  *
  40.  * This structure must only be allocated by asl.library amd is READ-ONLY!
  41.  * Control of the various fields is provided via tags when the requester
  42.  * is created with AllocAslRequest() and when it is displayed via
  43.  * AslRequest()
  44.  }
  45.  
  46. Type
  47.        pFileRequester = ^tFileRequester;
  48.        tFileRequester = record
  49.            rf_Reserved0   : Array[0..3] Of Byte;
  50.            rf_File        : STRPTR;        { Filename pointer             }
  51.            rf_Dir         : STRPTR;        { Directory name pointer       }
  52.            rf_Reserved1   : Array[0..9] Of Byte;
  53.            rf_LeftEdge    : Integer;
  54.            rf_TopEdge     : Integer;          { Preferred window pos }
  55.            rf_Width       : Integer;
  56.            rf_Height      : Integer;          { Preferred window size  }
  57.            rf_Reserved2   : Array[0..1] Of Byte;
  58.            rf_NumArgs     : LongInt;       { A-la WB Args, FOR multiselects }
  59.            rf_ArgList     : pWBArg
  60.            rf_UserData    : Pointer;       { Applihandle (you may write!!) }
  61.            rf_Reserved3   : Array[0..7] Of Byte;
  62.            rf_Pat         : STRPTR;        { Pattern match pointer }
  63.        END;                                { note - more reserved fields follow }
  64.  
  65.  
  66. { File requester tag values, used by AllocAslRequest() and AslRequest() }
  67.  
  68. const
  69. { Window control }
  70.   ASLFR_Window         = ASL_TB+2 ;  { Parent window                    }
  71.   ASLFR_Screen         = ASL_TB+40;  { Screen to open on if no window   }
  72.   ASLFR_PubScreenName  = ASL_TB+41;  { Name of public screen            }
  73.   ASLFR_PrivateIDCMP   = ASL_TB+42;  { Allocate private IDCMP?          }
  74.   ASLFR_IntuiMsgFunc   = ASL_TB+70;  { Function to handle IntuiMessages }
  75.   ASLFR_SleepWindow    = ASL_TB+43;  { Block input in ASLFR_Window?     }
  76.   ASLFR_UserData       = ASL_TB+52;  { What to put in fr_UserData       }
  77.  
  78. { Text display }
  79.   ASLFR_TextAttr       = ASL_TB+51;  { Text font to use for gadget text }
  80.   ASLFR_Locale         = ASL_TB+50;  { Locale ASL should use for text   }
  81.   ASLFR_TitleText      = ASL_TB+1 ;  { Title of requester               }
  82.   ASLFR_PositiveText   = ASL_TB+18;  { Positive gadget text             }
  83.   ASLFR_NegativeText   = ASL_TB+19;  { Negative gadget text             }
  84.  
  85. { Initial settings }
  86.   ASLFR_InitialLeftEdge= ASL_TB+3 ;  { Initial requester coordinates    }
  87.   ASLFR_InitialTopEdge = ASL_TB+4 ;
  88.   ASLFR_InitialWidth   = ASL_TB+5 ;  { Initial requester dimensions     }
  89.   ASLFR_InitialHeight  = ASL_TB+6 ;
  90.   ASLFR_InitialFile    = ASL_TB+8 ;  { Initial contents of File gadget  }
  91.   ASLFR_InitialDrawer  = ASL_TB+9 ;  { Initial contents of Drawer gadg. }
  92.   ASLFR_InitialPattern = ASL_TB+10;  { Initial contents of Pattern gadg.}
  93.  
  94. { Options }
  95.   ASLFR_Flags1         = ASL_TB+20;  { Option flags                     }
  96.   ASLFR_Flags2         = ASL_TB+22;  { Additional option flags          }
  97.   ASLFR_DoSaveMode     = ASL_TB+44;  { Being used for saving?           }
  98.   ASLFR_DoMultiSelect  = ASL_TB+45;  { Do multi-select?                 }
  99.   ASLFR_DoPatterns     = ASL_TB+46;  { Display a Pattern gadget?        }
  100.  
  101. { Filtering }
  102.   ASLFR_DrawersOnly    = ASL_TB+47;  { Don't display files?             }
  103.   ASLFR_FilterFunc     = ASL_TB+49;  { Function to filter files         }
  104.   ASLFR_RejectIcons    = ASL_TB+60;  { Display .info files?             }
  105.   ASLFR_RejectPattern  = ASL_TB+61;  { Don't display files matching pat }
  106.   ASLFR_AcceptPattern  = ASL_TB+62;  { Accept only files matching pat   }
  107.   ASLFR_FilterDrawers  = ASL_TB+63;  { Also filter drawers with patterns}
  108.   ASLFR_HookFunc       = ASL_TB+7 ;  { Combined callback function       }
  109.  
  110. { Flag bits for the ASLFR_Flags1 tag }
  111.   FRB_FILTERFUNC     = 7;
  112.   FRB_INTUIFUNC      = 6;
  113.   FRB_DOSAVEMODE     = 5;
  114.   FRB_PRIVATEIDCMP   = 4;
  115.   FRB_DOMULTISELECT  = 3;
  116.   FRB_DOPATTERNS     = 0;
  117.  
  118.   FRF_FILTERFUNC     = 128;
  119.   FRF_INTUIFUNC      = 64;
  120.   FRF_DOSAVEMODE     = 32;
  121.   FRF_PRIVATEIDCMP   = 16;
  122.   FRF_DOMULTISELECT  = 8;
  123.   FRF_DOPATTERNS     = 1;
  124.  
  125. { Flag bits for the ASLFR_Flags2 tag }
  126.   FRB_DRAWERSONLY    = 0;
  127.   FRB_FILTERDRAWERS  = 1;
  128.   FRB_REJECTICONS    = 2;
  129.  
  130.   FRF_DRAWERSONLY    = 1;
  131.   FRF_FILTERDRAWERS  = 2;
  132.   FRF_REJECTICONS    = 4;
  133.  
  134.  
  135. {****************************************************************************
  136.  *
  137.  * ASL Font Requester data structures and constants
  138.  *
  139.  * This structure must only be allocated by asl.library amd is READ-ONLY!
  140.  * Control of the various fields is provided via tags when the requester
  141.  * is created with AllocAslRequest() and when it is displayed via
  142.  * AslRequest()
  143.  }
  144.  
  145. Type
  146.     pFontRequester = ^tFontRequester;
  147.     tFontRequester = record
  148.        fo_Reserved0        : Array[0..7] Of Byte;
  149.        fo_Attr             : tTextAttr;            { Returned TextAttr                }
  150.        fo_FrontPen         : Byte;                 { Returned front pen               }
  151.        fo_BackPen          : Byte;                 { Returned back pen                }
  152.        fo_DrawMode         : Byte;                 { Returned drawing mode            }
  153.        fo_Reserved1        : Byte;
  154.        fo_UserData         : Pointer;              { You can store your own data here }
  155.        fo_LeftEdge         : Integer;                 { Coordinates Of requester on Exit }
  156.        fo_TopEdge          : Integer;
  157.        fo_Width            : Integer;
  158.        fo_Height           : Integer;
  159.        fo_TAttr            : tTTextAttr;           { Returned TTextAttr               }
  160.     end;
  161.  
  162.  
  163. { Font requester tag values, used by AllocAslRequest() AND AslRequest() }
  164.  
  165. const
  166. { Window control }
  167.   ASLFO_Window         = ASL_TB+2 ;  { Parent window                    }
  168.   ASLFO_Screen         = ASL_TB+40;  { Screen to open on if no window   }
  169.   ASLFO_PubScreenName  = ASL_TB+41;  { Name of public screen            }
  170.   ASLFO_PrivateIDCMP   = ASL_TB+42;  { Allocate private IDCMP?          }
  171.   ASLFO_IntuiMsgFunc   = ASL_TB+70;  { Function to handle IntuiMessages }
  172.   ASLFO_SleepWindow    = ASL_TB+43;  { Block input in ASLFO_Window?     }
  173.   ASLFO_UserData       = ASL_TB+52;  { What to put in fo_UserData       }
  174.  
  175. { Text display }
  176.   ASLFO_TextAttr       = ASL_TB+51;  { Text font to use for gadget text }
  177.   ASLFO_Locale         = ASL_TB+50;  { Locale ASL should use for text   }
  178.   ASLFO_TitleText      = ASL_TB+1 ;  { Title of requester               }
  179.   ASLFO_PositiveText   = ASL_TB+18;  { Positive gadget text             }
  180.   ASLFO_NegativeText   = ASL_TB+19;  { Negative gadget text             }
  181.  
  182. { Initial settings }
  183.   ASLFO_InitialLeftEdge= ASL_TB+3 ;  { Initial requester coordinates    }
  184.   ASLFO_InitialTopEdge = ASL_TB+4 ;
  185.   ASLFO_InitialWidth   = ASL_TB+5 ;  { Initial requester dimensions     }
  186.   ASLFO_InitialHeight  = ASL_TB+6 ;
  187.   ASLFO_InitialName    = ASL_TB+10;  { Initial contents of Name gadget  }
  188.   ASLFO_InitialSize    = ASL_TB+11;  { Initial contents of Size gadget  }
  189.   ASLFO_InitialStyle   = ASL_TB+12;  { Initial font style               }
  190.   ASLFO_InitialFlags   = ASL_TB+13;  { Initial font flags for TextAttr  }
  191.   ASLFO_InitialFrontPen= ASL_TB+14;  { Initial front pen                }
  192.   ASLFO_InitialBackPen = ASL_TB+15;  { Initial back pen                 }
  193.   ASLFO_InitialDrawMode= ASL_TB+59;  { Initial draw mode                }
  194.  
  195. { Options }
  196.   ASLFO_Flags          = ASL_TB+20;  { Option flags                     }
  197.   ASLFO_DoFrontPen     = ASL_TB+44;  { Display Front color selector?    }
  198.   ASLFO_DoBackPen      = ASL_TB+45;  { Display Back color selector?     }
  199.   ASLFO_DoStyle        = ASL_TB+46;  { Display Style checkboxes?        }
  200.   ASLFO_DoDrawMode     = ASL_TB+47;  { Display DrawMode cycle gadget?   }
  201.  
  202. { Filtering }
  203.   ASLFO_FixedWidthOnly = ASL_TB+48;  { Only allow fixed-width fonts?    }
  204.   ASLFO_MinHeight      = ASL_TB+16;  { Minimum font height to display   }
  205.   ASLFO_MaxHeight      = ASL_TB+17;  { Maximum font height to display   }
  206.   ASLFO_FilterFunc     = ASL_TB+49;  { Function to filter fonts         }
  207.   ASLFO_HookFunc       = ASL_TB+7 ;  { Combined callback function       }
  208.   ASLFO_MaxFrontPen    = ASL_TB+66;  { Max # of colors in front palette }
  209.   ASLFO_MaxBackPen     = ASL_TB+67;  { Max # of colors in back palette  }
  210.  
  211. { Custom additions }
  212.   ASLFO_ModeList       = ASL_TB+21;  { Substitute list for drawmodes    }
  213.   ASLFO_FrontPens      = ASL_TB+64;  { Color table for front pen palette}
  214.   ASLFO_BackPens       = ASL_TB+65;  { Color table for back pen palette }
  215.  
  216. { Flag bits for ASLFO_Flags tag }
  217.   FOB_DOFRONTPEN    =  0;
  218.   FOB_DOBACKPEN     =  1;
  219.   FOB_DOSTYLE       =  2;
  220.   FOB_DODRAWMODE    =  3;
  221.   FOB_FIXEDWIDTHONLY=  4;
  222.   FOB_PRIVATEIDCMP  =  5;
  223.   FOB_INTUIFUNC     =  6;
  224.   FOB_FILTERFUNC    =  7;
  225.  
  226.   FOF_DOFRONTPEN     = 1;
  227.   FOF_DOBACKPEN      = 2;
  228.   FOF_DOSTYLE        = 4;
  229.   FOF_DODRAWMODE     = 8;
  230.   FOF_FIXEDWIDTHONLY = 16;
  231.   FOF_PRIVATEIDCMP   = 32;
  232.   FOF_INTUIFUNC      = 64;
  233.   FOF_FILTERFUNC     = 128;
  234.  
  235. {****************************************************************************
  236.  *
  237.  * ASL Screen Mode Requester data structures and constants
  238.  *
  239.  * This structure must only be allocated by asl.library and is READ-ONLY!
  240.  * Control of the various fields is provided via tags when the requester
  241.  * is created with AllocAslRequest() and when it is displayed via
  242.  * AslRequest()
  243.  }
  244.  
  245. Type
  246.  pScreenModeRequester = ^tScreenModeRequester;
  247.  tScreenModeRequester = record
  248.     sm_DisplayID        : ULONG;    { Display mode ID                  }
  249.     sm_DisplayWidth     : ULONG;    { Width Of display IN pixels       }
  250.     sm_DisplayHeight    : ULONG;    { Height Of display IN pixels      }
  251.     sm_DisplayDepth     : word;     { Number OF bit-planes OF display  }
  252.     sm_OverscanType     : word;     { TYPE OF overscan OF display      }
  253.     sm_AutoScroll       : Boolean;  { Display should auto-scroll?      }
  254.  
  255.     sm_BitMapWidth      : ULONG;    { Used TO create your own BitMap   }
  256.     sm_BitMapHeight     : ULONG;
  257.  
  258.     sm_LeftEdge         : Integer;     { Coordinates OF requester on Exit }
  259.     sm_TopEdge          : Integer;
  260.     sm_Width            : Integer;
  261.     sm_Height           : Integer;
  262.  
  263.     sm_InfoOpened       : Boolean;  { Info window opened on exit?      }
  264.     sm_InfoLeftEdge     : Integer;     { Last coordinates OF Info window  }
  265.     sm_InfoTopEdge      : Integer;
  266.     sm_InfoWidth        : Integer;
  267.     sm_InfoHeight       : Integer;
  268.  
  269.     sm_UserData         : Pointer;     { You can store your own data here }
  270.  END;
  271.  
  272.  
  273. { An Exec list of custom modes can be added to the list of available modes.
  274.  * The DimensionInfo structure must be completely initialized, including the
  275.  * Header. See <graphics/displayinfo.h>. Custom mode ID's must be in the range
  276.  * $FFFF0000..$FFFFFFFF. Regular properties which apply to your custom modes
  277.  * can be added in the dn_PropertyFlags field. Custom properties are not
  278.  * allowed.
  279.  }
  280.  pDisplayMode = ^tDisplayMode;
  281.  tDisplayMode = record
  282.     dm_Node     : tNode;                 { see ln_Name           }
  283.     dm_DimensionInfo : tDimensionInfo;   { mode description      }
  284.     dm_PropertyFlags : ULONG;           { applicable properties }
  285.  end;
  286.  
  287.  
  288. { ScreenMode requester tag values, used by AllocAslRequest() and AslRequest() }
  289. const
  290. { Window control }
  291.   ASLSM_Window        =  ASL_TB+2 ;  { Parent window                    }
  292.   ASLSM_Screen        =  ASL_TB+40;  { Screen to open on if no window   }
  293.   ASLSM_PubScreenName =  ASL_TB+41;  { Name of public screen            }
  294.   ASLSM_PrivateIDCMP  =  ASL_TB+42;  { Allocate private IDCMP?          }
  295.   ASLSM_IntuiMsgFunc  =  ASL_TB+70;  { Function to handle IntuiMessages }
  296.   ASLSM_SleepWindow   =  ASL_TB+43;  { Block input in ASLSM_Window?     }
  297.   ASLSM_UserData      =  ASL_TB+52;  { What to put in sm_UserData       }
  298.  
  299. { Text display }
  300.   ASLSM_TextAttr      =  ASL_TB+51;  { Text font to use for gadget text }
  301.   ASLSM_Locale        =  ASL_TB+50;  { Locale ASL should use for text   }
  302.   ASLSM_TitleText     =  ASL_TB+1 ;  { Title of requester               }
  303.   ASLSM_PositiveText  =  ASL_TB+18;  { Positive gadget text             }
  304.   ASLSM_NegativeText  =  ASL_TB+19;  { Negative gadget text             }
  305.  
  306. { Initial settings }
  307.   ASLSM_InitialLeftEdge      = ASL_TB+3  ; { Initial requester coordinates    }
  308.   ASLSM_InitialTopEdge       = ASL_TB+4  ;
  309.   ASLSM_InitialWidth         = ASL_TB+5  ; { Initial requester dimensions     }
  310.   ASLSM_InitialHeight        = ASL_TB+6  ;
  311.   ASLSM_InitialDisplayID     = ASL_TB+100; { Initial display mode id     }
  312.   ASLSM_InitialDisplayWidth  = ASL_TB+101; { Initial display width       }
  313.   ASLSM_InitialDisplayHeight = ASL_TB+102; { Initial display height      }
  314.   ASLSM_InitialDisplayDepth  = ASL_TB+103; { Initial display depth       }
  315.   ASLSM_InitialOverscanType  = ASL_TB+104; { Initial type of overscan    }
  316.   ASLSM_InitialAutoScroll    = ASL_TB+105; { Initial autoscroll setting  }
  317.   ASLSM_InitialInfoOpened    = ASL_TB+106; { Info wndw initially opened? }
  318.   ASLSM_InitialInfoLeftEdge  = ASL_TB+107; { Initial Info window coords. }
  319.   ASLSM_InitialInfoTopEdge   = ASL_TB+108;
  320.  
  321. { Options }
  322.   ASLSM_DoWidth         = ASL_TB+109;  { Display Width gadget?           }
  323.   ASLSM_DoHeight        = ASL_TB+110;  { Display Height gadget?          }
  324.   ASLSM_DoDepth         = ASL_TB+111;  { Display Depth gadget?           }
  325.   ASLSM_DoOverscanType  = ASL_TB+112;  { Display Overscan Type gadget?   }
  326.   ASLSM_DoAutoScroll    = ASL_TB+113;  { Display AutoScroll gadget?      }
  327.  
  328. { Filtering }
  329.   ASLSM_PropertyFlags   = ASL_TB+114;  { Must have these Property flags  }
  330.   ASLSM_PropertyMask    = ASL_TB+115;  { Only these should be looked at  }
  331.   ASLSM_MinWidth        = ASL_TB+116;  { Minimum display width to allow  }
  332.   ASLSM_MaxWidth        = ASL_TB+117;  { Maximum display width to allow  }
  333.   ASLSM_MinHeight       = ASL_TB+118;  { Minimum display height to allow }
  334.   ASLSM_MaxHeight       = ASL_TB+119;  { Maximum display height to allow }
  335.   ASLSM_MinDepth        = ASL_TB+120;  { Minimum display depth           }
  336.   ASLSM_MaxDepth        = ASL_TB+121;  { Maximum display depth           }
  337.   ASLSM_FilterFunc      = ASL_TB+122;  { Function to filter mode id's    }
  338.  
  339. { Custom additions }
  340.   ASLSM_CustomSMList    = ASL_TB+123;  { Exec list of struct DisplayMode }
  341.  
  342.  
  343. {****************************************************************************
  344.  *
  345.  * Obsolete ASL definitions, here for source code compatibility only.
  346.  * Please do NOT use in new code.
  347.  *
  348.  *   ASL_V38_NAMES_ONLY to remove these older names
  349.  }
  350. Const
  351.   ASL_Dummy       = (TAG_USER + $80000);
  352.   ASL_Hail        = ASL_Dummy+1 ;
  353.   ASL_Window      = ASL_Dummy+2 ;
  354.   ASL_LeftEdge    = ASL_Dummy+3 ;
  355.   ASL_TopEdge     = ASL_Dummy+4 ;
  356.   ASL_Width       = ASL_Dummy+5 ;
  357.   ASL_Height      = ASL_Dummy+6 ;
  358.   ASL_HookFunc    = ASL_Dummy+7 ;
  359.   ASL_File        = ASL_Dummy+8 ;
  360.   ASL_Dir         = ASL_Dummy+9 ;
  361.   ASL_FontName    = ASL_Dummy+10;
  362.   ASL_FontHeight  = ASL_Dummy+11;
  363.   ASL_FontStyles  = ASL_Dummy+12;
  364.   ASL_FontFlags   = ASL_Dummy+13;
  365.   ASL_FrontPen    = ASL_Dummy+14;
  366.   ASL_BackPen     = ASL_Dummy+15;
  367.   ASL_MinHeight   = ASL_Dummy+16;
  368.   ASL_MaxHeight   = ASL_Dummy+17;
  369.   ASL_OKText      = ASL_Dummy+18;
  370.   ASL_CancelText  = ASL_Dummy+19;
  371.   ASL_FuncFlags   = ASL_Dummy+20;
  372.   ASL_ModeList    = ASL_Dummy+21;
  373.   ASL_ExtFlags1   = ASL_Dummy+22;
  374.   ASL_Pattern     = ASL_FontName;
  375. { remember what I said up there? Do not use these anymore! }
  376.   FILB_DOWILDFUNC  = 7;
  377.   FILB_DOMSGFUNC   = 6;
  378.   FILB_SAVE        = 5;
  379.   FILB_NEWIDCMP    = 4;
  380.   FILB_MULTISELECT = 3;
  381.   FILB_PATGAD      = 0;
  382.   FILF_DOWILDFUNC  = 128;
  383.   FILF_DOMSGFUNC   = 64;
  384.   FILF_SAVE        = 32;
  385.   FILF_NEWIDCMP    = 16;
  386.   FILF_MULTISELECT = 8;
  387.   FILF_PATGAD      = 1;
  388.   FIL1B_NOFILES    = 0;
  389.   FIL1B_MATCHDIRS  = 1;
  390.   FIL1F_NOFILES    = 1;
  391.   FIL1F_MATCHDIRS  = 2;
  392.   FONB_FRONTCOLOR  = 0;
  393.   FONB_BACKCOLOR   = 1;
  394.   FONB_STYLES      = 2;
  395.   FONB_DRAWMODE    = 3;
  396.   FONB_FIXEDWIDTH  = 4;
  397.   FONB_NEWIDCMP    = 5;
  398.   FONB_DOMSGFUNC   = 6;
  399.   FONB_DOWILDFUNC  = 7;
  400.   FONF_FRONTCOLOR  = 1;
  401.   FONF_BACKCOLOR   = 2;
  402.   FONF_STYLES      = 4;
  403.   FONF_DRAWMODE    = 8;
  404.   FONF_FIXEDWIDTH  = 16;
  405.   FONF_NEWIDCMP    = 32;
  406.   FONF_DOMSGFUNC   = 64;
  407.   FONF_DOWILDFUNC  = 128;
  408.  
  409.  
  410. VAR AslBase : pLibrary;
  411.  
  412. FUNCTION AllocAslRequest(reqType : ULONG; tagList : pTagItem) : POINTER;
  413. FUNCTION AllocFileRequest : pFileRequester;
  414. FUNCTION AslRequest(requester : POINTER; tagList : pTagItem) : BOOLEAN;
  415. PROCEDURE FreeAslRequest(requester : POINTER);
  416. PROCEDURE FreeFileRequest(fileReq : pFileRequester);
  417. FUNCTION RequestFile(fileReq : pFileRequester) : BOOLEAN;
  418.  
  419. IMPLEMENTATION
  420.  
  421. FUNCTION AllocAslRequest(reqType : ULONG; tagList : pTagItem) : POINTER;
  422. BEGIN
  423.   ASM
  424.     MOVE.L  A6,-(A7)
  425.     MOVE.L  reqType,D0
  426.     MOVEA.L tagList,A0
  427.     MOVEA.L AslBase,A6
  428.     JSR -048(A6)
  429.     MOVEA.L (A7)+,A6
  430.     MOVE.L  D0,@RESULT
  431.   END;
  432. END;
  433.  
  434. FUNCTION AllocFileRequest : pFileRequester;
  435. BEGIN
  436.   ASM
  437.     MOVE.L  A6,-(A7)
  438.     MOVEA.L AslBase,A6
  439.     JSR -030(A6)
  440.     MOVEA.L (A7)+,A6
  441.     MOVE.L  D0,@RESULT
  442.   END;
  443. END;
  444.  
  445. FUNCTION AslRequest(requester : POINTER; tagList : pTagItem) : BOOLEAN;
  446. BEGIN
  447.   ASM
  448.     MOVE.L  A6,-(A7)
  449.     MOVEA.L requester,A0
  450.     MOVEA.L tagList,A1
  451.     MOVEA.L AslBase,A6
  452.     JSR -060(A6)
  453.     MOVEA.L (A7)+,A6
  454.     TST.W   D0
  455.     BEQ.B   @end
  456.     MOVEQ   #1,D0
  457.   @end: MOVE.B  D0,@RESULT
  458.   END;
  459. END;
  460.  
  461. PROCEDURE FreeAslRequest(requester : POINTER);
  462. BEGIN
  463.   ASM
  464.     MOVE.L  A6,-(A7)
  465.     MOVEA.L requester,A0
  466.     MOVEA.L AslBase,A6
  467.     JSR -054(A6)
  468.     MOVEA.L (A7)+,A6
  469.   END;
  470. END;
  471.  
  472. PROCEDURE FreeFileRequest(fileReq : pFileRequester);
  473. BEGIN
  474.   ASM
  475.     MOVE.L  A6,-(A7)
  476.     MOVEA.L fileReq,A0
  477.     MOVEA.L AslBase,A6
  478.     JSR -036(A6)
  479.     MOVEA.L (A7)+,A6
  480.   END;
  481. END;
  482.  
  483. FUNCTION RequestFile(fileReq : pFileRequester) : BOOLEAN;
  484. BEGIN
  485.   ASM
  486.     MOVE.L  A6,-(A7)
  487.     MOVEA.L fileReq,A0
  488.     MOVEA.L AslBase,A6
  489.     JSR -042(A6)
  490.     MOVEA.L (A7)+,A6
  491.     TST.W   D0
  492.     BEQ.B   @end
  493.     MOVEQ   #1,D0
  494.   @end: MOVE.B  D0,@RESULT
  495.   END;
  496. END;
  497.  
  498. END. (* UNIT ASL *)
  499.